.session-list {
  height: 100%;
  overflow-y: auto;
  padding: 16px;
  background-color: #ffffff;
}

.session-list .ant-card {
  height: 100%;
  box-shadow: 0 1px 2px rgba(0, 0, 0, 0.05);
}

.session-list .ant-card-body {
  height: calc(100% - 57px);
  display: flex;
  flex-direction: column;
  padding: 16px;
}

.session-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.session-list .ant-list {
  flex: 1;
  overflow-y: auto;
  margin-top: 8px;
}

.session-item {
  cursor: pointer;
  transition: all 0.3s;
  border-radius: 4px;
  margin: 4px 0;
  padding: 8px 12px;
  border: 1px solid transparent;
}

.session-item:hover {
  background-color: #f5f5f5;
  border-color: #e8e8e8;
}

.session-item.active {
  background-color: #e6f7ff;
  border-color: #1890ff;
}

.session-item .ant-list-item-meta {
  align-items: center;
  margin-bottom: 0;
}

.session-item .ant-list-item-meta-avatar {
  margin-right: 12px;
}

.session-item .ant-list-item-meta-title {
  margin-bottom: 4px;
  color: #000000d9;
  font-weight: 500;
}

.session-item .ant-list-item-meta-description {
  color: #00000073;
  font-size: 12px;
}

.session-item .session-group {
  margin-top: 4px;
  color: #00000040;
  font-size: 12px;
}

.session-item .ant-list-item-action {
  margin-left: 12px;
}

.session-item .ant-badge {
  display: flex;
  align-items: center;
}

.session-item .ant-badge-status-dot {
  width: 8px;
  height: 8px;
}

.session-item .ant-badge-status-text {
  margin-left: 8px;
  font-size: 12px;
}

/* 操作按钮样式 */
.session-item .ant-btn-text {
  width: 32px;
  height: 32px;
  padding: 0;
  display: flex;
  align-items: center;
  justify-content: center;
}

.session-item .ant-btn-text:hover {
  background-color: rgba(0, 0, 0, 0.04);
}

/* 下拉菜单样式 */
.ant-dropdown-menu-item {
  padding: 8px 12px;
}

.ant-dropdown-menu-item .anticon {
  margin-right: 8px;
}

/* 表单样式 */
.ant-modal-body .ant-form-item:last-child {
  margin-bottom: 0;
}

.ant-modal-body .ant-upload-wrapper {
  width: 100%;
}

.ant-modal-body .ant-upload-wrapper .ant-upload-select {
  width: 100%;
}

.ant-modal-body .ant-upload-wrapper .ant-upload-select .ant-btn {
  width: 100%;
}

/* 搜索框样式 */
.session-list .ant-input-search {
  width: 200px;
}

.session-list .ant-input-search .ant-input {
  border-radius: 4px;
}

.session-list .ant-input-search .ant-input:focus,
.session-list .ant-input-search .ant-input:hover {
  border-color: #1890ff;
  box-shadow: 0 0 0 2px rgba(24, 144, 255, 0.2);
}

.session-list .ant-input-search .ant-input-clear-icon:hover {
  color: #1890ff;
}

.session-list {
  height: 100%;
}

.session-list .ant-card {
  height: 100%;
  display: flex;
  flex-direction: column;
}

.session-list .ant-card-body {
  flex: 1;
  overflow: auto;
  padding: 12px;
}

.session-list-header {
  display: flex;
  justify-content: space-between;
  align-items: center;
  margin-bottom: 16px;
}

.session-list-actions {
  display: flex;
  gap: 8px;
}

.session-tree {
  margin-top: 8px;
}

.group-node {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
}

.group-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.group-count {
  font-size: 12px;
  color: rgba(0, 0, 0, 0.45);
}

.group-actions {
  display: none;
  gap: 4px;
}

.group-node:hover .group-actions {
  display: flex;
}

.session-node {
  display: flex;
  justify-content: space-between;
  align-items: center;
  width: 100%;
  padding: 4px 0;
}

.session-info {
  flex: 1;
  min-width: 0;
}

.session-title {
  display: flex;
  align-items: center;
  gap: 8px;
}

.session-name {
  font-weight: 500;
}

.session-subtitle {
  font-size: 11px;
  color: rgba(0, 0, 0, 0.45);
  white-space: nowrap;
}

.session-actions {
  display: flex;
  gap: 4px;
  margin-left: 8px;
  flex-shrink: 0;
}

/* 暗色主题适配 */
[data-theme='dark'] .group-count,
[data-theme='dark'] .session-subtitle {
  color: rgba(255, 255, 255, 0.45);
}

/* 拖拽样式 */
.session-tree .ant-tree-node-content-wrapper {
  width: 100%;
}

.session-tree .ant-tree-draggable-icon {
  cursor: move;
}

/* 优化Tree组件布局 */
.session-tree .ant-tree-treenode {
  padding: 2px 0;
}

.session-tree .ant-tree-node-content-wrapper {
  padding: 2px 4px;
  border-radius: 4px;
  display: flex;
  align-items: center;
}

.session-tree .ant-tree-node-content-wrapper:hover {
  background-color: #f5f5f5;
}

.session-tree .ant-tree-node-content-wrapper.ant-tree-node-selected {
  background-color: #e6f7ff;
}

/* 调整图标和内容的间距 */
.session-tree .ant-tree-iconEle {
  margin-right: 4px;
  flex-shrink: 0;
}

/* 让title内容占满剩余空间 */
.session-tree .ant-tree-title {
  flex: 1;
  display: flex;
  align-items: center;
}

/* 隐藏连接线，让布局更紧凑 */
.session-tree .ant-tree-indent-unit {
  width: 16px;
}

.session-tree .ant-tree-switcher {
  width: 16px;
  height: 20px;
  line-height: 20px;
}

/* 确保整个树节点内容在同一行 */
.session-tree .ant-tree-treenode-leaf-last > .ant-tree-node-content-wrapper,
.session-tree .ant-tree-treenode-leaf-last > .ant-tree-node-content-wrapper > .ant-tree-title {
  display: flex;
  align-items: center;
}